import React, {Component} from 'react';

class BlockNote extends Component {
    render() {
        const {title, data} = this.props;

        return (
            <div className="leave-note-block-div">
                {title && <div className="leave-note-title-div">
                    {title}
                </div>}
                {data && data.map((v) => {
                    return <div style={{margin: "6px 0", fontSize: "16px"}} key={v.title}>
                        <span style={{display: "inline-block", width: "120px", color: "#8c8c8c"}}>{v.title}</span>
                        <span style={{display: "inline-block", marginLeft: "4px", width: "220px"}}>{v.value}</span>
                    </div>
                })}
            </div>
        );
    }
}

export default BlockNote;
